import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

// 页面组件
import Home from '../views/Home.vue'
import QuickStart from '../views/QuickStart.vue'
import DynamicData from '../views/echart5Feature/DynamicData.vue'
import DrillDown from '../views/pratice/DrillDown.vue'

const routes = [
    {
        path: '/',
        name: 'Home',
        components: {
            mainDiv: Home
        }
    },
    {
        path: '/quickStart',
        name: 'QuickStart',
        components: {
            mainDiv: QuickStart
        }
    },
    {
        path: '/echart5Feature/DynamicData',
        name: 'DynamicData',
        components: {
            mainDiv: DynamicData
        }
    },
    {
        path: '/pratice/DrillDown',
        name: 'DrillDown',
        components: {
            mainDiv: DrillDown
        }
    },
]

const router = new VueRouter({
    mode: 'history',
    base: process.env.BASE_URL,
    routes
})

export default router
